(function($) {
	$(document.body).removeClass('no-js');
	var $window = $(window),
		$nav = $('#top-links'),
		$slider = $('#slider'),
		$sticky_1 = $('#sticky-1'),
		$sticky_2 = $('#sticky-2'),
		$tabLinks = $('#tab-area .tab-unit a'),
		$tabContent = $('#tab-area .tab-content');
	$nav.find('li.has-ul > a').on("click", function() {
		$(this).next().slideToggle();
		return false;
	});
	$sticky_1.stickyBar({animated:true,top:60,until:'.quick-tool-block'});
	$sticky_2.stickyBar({fixedClass:'sticked'});
	$window.on("resize", function() {
		$('.space-holder').remove();
		$sticky_1.css('position','static').stickyBar({animated:true,top:60,until:'.quick-tool-block'});
		$sticky_2.css('position','static').stickyBar({fixedClass:'sticked'});
	}).trigger("resize").on("load", function() {
		$slider.nivoSlider({effect:"boxRandom",directionNav:false});
	});
	$tabLinks.on("click", function() {
		$tabContent.hide();
		$(this.hash).fadeIn(400);
		$tabLinks.removeClass('active');
		$(this).addClass('active');
		return false;
	}).first().trigger("click");
})(jQuery);